1. Field
Apparatuses and methods consistent with the exemplary embodiments relate to a method and device for protecting data of a flash memory, and more particularly to a method and device for protecting data of a flash memory, which can prevent data from being changed or deleted while an apparatus including the flash memory is powered on or off.
2. Description of the Related Art
Electronic appliances have employed a flash memory. The flash memory has been widely used in portable electronic appliances since it can maintain data even when the appliance is powered off. The flash memory includes a writing-protection pin so that its data can be protected.
FIG. 5 is a view illustrating a related art flash memory 12 supplied with power and controlled by a controller 14. A primary direct current (DC) power supply of about 12V is applied to the flash memory 12. This primary power is converted into about 3.3V DC through a DC/DC converter 11 and then applied to the power input terminals VCC of the flash memory 12 and the controller 14. The controller 14 applies a control signal to the writing-protection pin WP of the flash memory 12 through a general purpose input/output (GPIO) terminal, thereby enabling or disabling the writing-protection pin WP of the flash memory 12.
Accordingly, the writing-protection pin WR of the flash memory 12 is controlled by the controller 14 such as a micro processing unit (MCU) or a central processing unit (CPU), while stably maintaining the power constant, so that the data of the flash memory 12 can be stably protected.
However, when the electronic appliance including the flash memory 12 is powered on or off, the data stored in the flash memory 12 may be corrupted. Accordingly, a method for protecting the data of the flash memory 12 is required when the electronic appliance is powered on or off.